package com.company;

import com.company.createtype.factoryfunction.CarFactory;
import com.company.createtype.factoryfunction.IMethodFactory;
import com.company.createtype.factoryfunction.ToyFactory;
import com.company.createtype.simpleFactory.Factory;

public class Main {

    public static void main(String[] args) {
	// write your code here
    }

    private void simpleFactory(){
        //Factory 需要知道每一个type 对应的product实现
        Product product = Factory.createProduct(0);
    }
    private void factoryMethod(){
        //需要知道每一个工厂实现
        IMethodFactory toyFactory = new ToyFactory();
        Product toy = toyFactory.create();

        IMethodFactory carFactory = new CarFactory();
        Product car = carFactory.create();
    }
    private void absFactory(){

    }

}
